{% extends 'base/base.html' %}
{% block title %}
    搜索结果
{% endblock %}

{% block main %}

    {% if query %}
        <h3>搜索结果如下：</h3>
        <ul class="group1">
            {% for article in page.object_list %}
                 <li>
                     <a href="{% url 'main:article_detail' article.object.id %}"> {{ article.object.content|safe }} {{ article.object.title }}</a>
                 </li>
            {% empty %}
                <p>啥也没找到</p>
            {% endfor %}
        </ul>
    {% endif %}
    <a class="btn btn-success" href="{% url 'main:index' %}">返回</a>
{% endblock %}